package dataStructure.xmg1.a05;

import dataStructure.xmg1.a05.list.LinkedList;
import dataStructure.xmg1.a05.list.List;

/**
 * @author: vince_zww
 * @date: 2020/11/29 13:44
 * @desceription:
 */
public class Queue<E> {

    private List<E> list = new LinkedList<>();

    public int size(){
        return list.size();
    }

    public void clear(){
        list.clear();
    }

    public boolean isEmpty(){
        return list.isEmpty();
    }

    public void enQueue(E element) {
        list.add(element);
    }

    public E deQueue(){
        return list.remove(0);
    }

    public E front(){
        return list.get(0);
    }


}
